from src import mysql_db as db

"""
异步处理结果表
"""


class SyncStatus(db.Model):
    __tablename__ = 'sync_status'
    dt = db.Column(db.String(100), comment="分区日期")
    uuid = db.Column(db.String(100), primary_key=True, comment="uuid")
    status = db.Column(db.Integer, comment="主键")
    create_time = db.Column(db.String(100), default='', comment="创建时间")
    update_time = db.Column(db.String(100), default='', comment="更新时间")


"""
补调用例表
"""


class MelonCase(db.Model):
    __tablename__ = "melon_case"
    dt = db.Column(db.String(100), comment="分区日期")
    case_id = db.Column(db.Integer, primary_key=True, comment="用例编号")
    case_name = db.Column(db.String(50), comment="用例名称")
    case_input = db.Column(db.String(1000), comment="用例入参")
    case_output_expected = db.Column(db.String(5000), comment="预期结果")
    case_output_real = db.Column(db.Integer, comment="实际结果")
    is_pass = db.Column(db.Integer, comment="1成功，0失败")
    yn = db.Column(db.Integer, comment="1是有效，0是删除")
    create_time = db.Column(db.String(100), default='', comment="用例创建时间")
    update_time = db.Column(db.String(100), default='', comment="用例更新时间")
